How to solve differential equations by substitution